home *** CD-ROM | disk | FTP | other *** search
/ NOVA - For the NeXT Workstation / NOVA - For the NeXT Workstation.iso / Documents / NeXTAnswers / appkit.703 < prev    next >
Text File  |  1992-02-06  |  2KB  |  38 lines

  1. {\rtf0\ansi{\fonttbl\f0\fnil Times-Roman;\f1\fswiss Helvetica;}
  2. \paperw12740
  3. \paperh8500
  4. \margl120
  5. \margr120
  6. {\colortbl\red0\green0\blue0;}
  7. \pard\tx960\tx1920\tx2880\tx3840\tx4800\tx5760\tx6720\tx7680\tx8640\tx9600\f0\b0\i0\ul0\fs28 Appkit NXJournaler masterJournaler slaveJournaler \
  8.     \
  9. Q:  
  10. \fc0 What are the functions of  the Application methods 
  11. \b masterJournaler
  12. \b0  and 
  13. \b slaveJournaler
  14. \b0 ?\
  15. \
  16. A: When you create an instance of the NXJournaler class, it automatically becomes the master Journaler for the application (you can only have one of these).  Slave journalers are created transparently to the programmer when an app is being recorded from or played back to.  Both are instances of NXJournaler.\
  17. \
  18. You would access the masterJournaler if your program didn't keep this instance variable around itself and you needed to get at your NXJournaler instance to start or stop recording or playback.\
  19. \
  20. It is rare that an app would want to get at its slaveJournaler.  This would happen if the app needed to do something different in a method if it knew that  it was being recorded from or played back to.  It would make a call to NXApp to get the slave. Then it could get the status of this slave journaler using 
  21. \b getEventStatus:soundStatus:eventStream:soundStream
  22. \b0 , and do something different based upon the result.\
  23. \
  24. Q: Why do I get a NIL journaler id when I want to access the slave journaler in my application?\
  25. \
  26. A:  You have to query for the slave journaler when the application is being recorded from or played back to by another journaling app. Otherwise, the slave journaler could not be instantiated yet.  Also, your application must allow itself to be journaled by other applications.  Use the method 
  27. \b [NXApp setJournalable:YES]
  28. \b0 .  Note that 
  29. \b setJournalable:YES
  30. \b0  is the default.  Both the journaling app and the app being journaled can be the same application.\
  31. \
  32. Not Valid for 1.0\
  33. Valid for 2.0\
  34. \
  35. QA703\
  36. \
  37.  
  38.